package com.jun.seckill_by_jun.dao;

import com.jun.seckill_by_jun.domain.Test;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

@Repository
@Mapper
public interface TestDao {
    @Insert("insert into test(id,name) values(#{id},#{name})")
    public int insert(Test test);
    @Select("select * from test where id =  #{id}")
    public Test getTestById(@Param("id") int id);
}
